import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router)

/* 路由模块*/
export const constantRouterMap = [
 {
	name: 'login',
	path: '/login',
	component: () =>import('@/views/login'),
	meta:{title: '登录'}
	},
   {
	 name: 'index',
	 path: '/',
	 component: () =>import('@/views/home'),
	 meta:{title: '首页'}
   }, 	
   {
	 name: 'pj',
	 path: '/pj',
	 component: ()=>import('@/views/pj/index'),
	 meta:{title:'学生评教'},
   },
   {
   	 name: 'finish',
   	 path: '/Info',
   	 component: ()=>import('@/views/pj/finishpj.vue'),
   	 meta:{title:'学生评教'},
   },
   {
	 name:'detail',
	 path:'/Info/detail',
	 component:()=>import('@/views/pj/detail.vue'),
	 meta:{title:'评教内容'},
   },
   {
	 name:'person',
	 path:'/person',
	 component:()=>import('@/views/person'),
	 meta:{title:'个人中心'}
   },
   {
	   name:'paperItem',
	   path:'/paperItem',
	   component:()=>import('@/views/pj/paperItem.vue'),
	   meta:{title:'问卷选项'}
   },
   {
	   name:'finishItem',
	   path:'/finishItem',
	   component:()=>import('@/views/pj/finishItem.vue'),
	   meta:{title:'查看评教'}
   },
   {
	 name:'server',
	 path:'/server',
	 component:()=>import('@/views/server/index'),
	 meta:{title:'服务中心'}
   },
   {
	   name:'teacher',
	   path:'/teacher',
	   component:()=>import('@/views/teacher/index'),
	   meta:{title:'教师首页'}
   },
   {
	 name:'detailScore',
	 path:'/detailScore',
	 component:()=>import('@/views/teacher/detailScore'),
	 meta:{title:'得分详情'}
   },
   {
	   name:'teacherInfo',
	   path:'/teacherInfo',
	   component:()=>import('@/views/teacher/teacherInfo'),
	   meta:{title:'教师信息'}
   },
   {
	   name:'rank',
	   path:'/rank',
	   component:()=>import('@/views/teacher/rank'),
	   meta:{title:'教师排名'}
   },
   {
	   name:'score',
	   path:'/score',
	   component:()=>import('@/views/score/index'),
	   meta:{title:'我的成绩'}
   },
   {
	   name:'register',
	   path:'/register',
	   component:()=>import('@/views/login/register'),
	   meta:{title:'注册'}
   }
]

export default new Router({
  mode: 'hash',
  scrollBehavior: () => ({ y: 0 }),
  routes: constantRouterMap
})
